ALMaSS  1.0
The Animal, Landscape and Man Simulation System
Roe_all.h
Go to the documentation of this file.
1 //---------------------------------------------------------------------------
2 #ifndef Roe_allH
3 #define Roe_allH
4 
5 //---------------------------------------------------------------------------
6 #include <math.h>
7 
8 #include <vector>
9 #include <algorithm>
10 #include <string>
11 
12 
13 //---------------------------------------------------------------------------
14 
15 using namespace std;
16 
17 
18 
19 //---------------------------------------------------------------------------
20 
21 class Roe_Base;
22 class Roe_Male;
23 class Roe_Female;
24 class Roe_Fawn;
25 class Roe_Adult_Base;
27 class TTypesOfElement;
28 class Grid;
29 class GridCell;
30 class MovementMap;
31 class probe_data;
32 
33 //---------------------------------------------------------------------------
34 
35 typedef vector<Roe_Fawn *> Roe_FawnList;
36 typedef vector<Roe_Male *> Roe_MaleList;
37 typedef vector<Roe_Female *> Roe_FemaleList;
38 // the arrays
39 typedef vector< Roe_Male *> ListOfMales;
40 typedef vector< Roe_Female *> ListOfFemales;
41 typedef vector< Roe_Base *> ListOfDeer;
42 
43 //---------------------------------------------------------------------------
44 
45 typedef enum {
95  }
97 //---------------------------------------------------------------------------
98 //---------------------------------------------------------------------------
99 
100 class Roe_Base : public TAnimal
101 {
102  public:
105  int m_Age; //in days
106  int m_Size; //body weight in gram
110  double m_HomeRange;
111  int m_OldRange_x; //stores roes own rangecentre while in group or dispersing
114  bool m_float;
118  int m_ID; //unique ID number
120  bool m_Sex; //true=male
121  bool m_IsDead;
122  unsigned Alive;
123  unsigned IsAlive() {return Alive;}
124 
125  int SupplyReserves() {return m_Reserves;}
126  private:
127  protected:
128  int timestep; //current timestep in this animals life
129 
132  double m_EnergyGained; //counter that keeps track of energy gained from feeding
133  int m_RecovCount; //counts time spend in recov. Set=0 when state is left
134  int m_RumiCount; //counts time spend ruminating. Set=0 when state is left
135  int m_FeedCount; //counts time spend feeding since end of last ruminate period
136  int m_LengthFeedPeriod;//calculated daily in UpdateEnergy, depends on date and body weight
138  int m_LastState; //holds the last state in before disturbance or NewDay
139  int m_danger_x; // co-ordinates to a source of danger - set by an
140  int m_danger_y; // ApproachOfDanger message
141  //for obstacle avoidance during very directed movement:
142  int m_distrc; //stores the last dist to rc
143  int m_weightedstep; //this many steps with weight during last hour
144  int SimW;
145  int SimH;
146  bool Running (int x,int y);
147  void Ignore (int p_To_x, int p_To_y);
148 
149  int DistanceTo (int p_x,int p_y, int p_To_x, int p_To_y);
150  int DistanceToCC (int p_x,int p_y, int p_To_x, int p_To_y)
151  {
152  m_OurLandscape->CorrectCoords( p_x, p_y );
153  m_OurLandscape->CorrectCoords( p_To_x, p_To_y );
154  return DistanceTo( p_x, p_y, p_To_x, p_To_y );
155  }
156 
157  int DirectionTo(int p_x,int p_y, int p_To_x, int p_To_y);
158  int DirectionToCC(int p_x,int p_y, int p_To_x, int p_To_y)
159  {
160  m_OurLandscape->CorrectCoords( p_x, p_y );
161  return DirectionTo( p_x, p_y, p_To_x, p_To_y );
162  }
163 
164  int NextStep (int weight,int dir, int recurselevel);
165  int AssessHabitat (int polyref);
166  int AssessHabitat (int p_x, int p_y);
167 
168  int LegalHabitat(int p_x,int p_y);
172  int LegalHabitatCC(int p_x,int p_y)
173  {
174  m_OurLandscape->CorrectCoords( p_x, p_y );
175  return LegalHabitat( p_x, p_y );
176  }
177 
178 
180  int Cover(int polyref);
182  int Cover(int p_x, int p_y);
184  int CalcCover(TTypesOfLandscapeElement a_ele, int a_poly);
188  int CoverCC(int p_x, int p_y) // Corrects coordinates, inline. **FN**
189  {
190  m_OurLandscape->CorrectCoords( p_x, p_y );
191  return Cover( p_x, p_y );
192  }
193 
194  int NutriValue(int polyref);
195  int NutriValue(int p_x, int p_y);
196  int NutriValueCC(int p_x, int p_y)
197  {
198  m_OurLandscape->CorrectCoords( p_x, p_y );
199  return NutriValue( p_x, p_y );
200  }
201 
202  int Feeding(bool p_Disperse);
203  void SeekCover(int threshold);
204  void SeekNutri(int p_threshold);
205  int ProbRoadCross (int p_x, int p_y, int p_width);
206  double CalculateRoadMortality (int p_x,int p_y,int p_width);
207 
208  void WalkTo(int pos_x, int pos_y);
209  void WalkToCC(int pos_x, int pos_y)
210  {
211  m_OurLandscape->CorrectCoords( pos_x, pos_y );
212  WalkTo( pos_x, pos_y );
213  }
214 
215 public:
216  virtual void On_MumAbandon(Roe_Female* /* mum */) {}
217  virtual void On_IsDead(Roe_Base* /* base */, int /* whos_dead */, bool /* fawn */){}
218  virtual void On_EndGroup() {}
219  virtual void Send_IsDead() {}
220  virtual void On_ChangeGroup(int /* newgroup */) {}
221  virtual void On_UpdateGroup(int /* p_group_x */,int /* p_group_y */) {}
222  RoeDeerInfo SupplyInfo();
223  virtual void BeginStep (void);
224  virtual void Step (void);
225  virtual void EndStep (void);
226  virtual int WhatState() {return (int) CurrentRState;}
227  Roe_Base(int x, int y, Landscape* L,RoeDeer_Population_Manager* RPM);
228  virtual ~Roe_Base();
229 };
230 //---------------------------------------------------------------------------
231 
232 class Roe_Adult_Base : public Roe_Base
233 {
234 public:
235 
236 protected:
237  bool m_DestinationDecided; //know where to go after OnNewDay
238  int m_NewState; //go to this state after OnNewDay
242 
243 public:
244  virtual void BeginStep (void);
245  virtual void Step (void);
246  virtual void EndStep (void);
247 
248  Roe_Adult_Base(int x, int y, int size,int age, Landscape* L,RoeDeer_Population_Manager* RPM);
249  virtual ~Roe_Adult_Base();
250 };
251 //---------------------------------------------------------------------------
252 
253 class Roe_Fawn : public Roe_Base
254 {
255 private:
256  //states
257  int FAInit(void);
258  int FASuckle(void);
259  int FAFeed(void);
260  int FARuminate(void);
261  int FAHide(void);
262  int FARecover(void);
263  int FARunToMother(void);
264  int FAOnNewDay(void);
265  int FAUpdateEnergy(void);
266  int FADie(void);
267 
268 protected:
269  Roe_Base* m_MySiblings[3]; //same age siblings
270  int BedSiteList[15][2];
272  bool m_Mature;
274  bool m_Orphan;
275  bool m_InHide;
278  unsigned m_Count; //counts every timestep for the first 60 days of fawns life (8640 timesteps)
279  int m_CareLastHour[6];
280  //dynamic list that counts last 6 timesteps as '1' if
281  //fawn has received the required care and '0' if not.
282 
283  int m_memorypointer; //no. of latest bedsite on bedsite list
284  void CareCounter(int state); //counts hourly care
285  void SelectBedSite ();
286  int RunTo(int mum_x, int mum_y, bool p_IsSafe);
287  void Mature();
288  void Send_InitCare();
289  void On_UpdateGroup(int p_group_x,int p_group_y);
290  void On_ApproachOfDanger(int p_To_x,int p_To_y);
291 public:
293  int m_MinInState[6]; //for energy calc., minuts spend in different states
294  //[0]=Run,[1]=Recov,[2]=Hide,[3]=Rumi,[4]=Feed,[5]=Suckle
295 public:
296  virtual void On_IsDead(Roe_Base* Someone, int whos_dead, bool fawn);
297  virtual void On_ChangeGroup(int newgroup);
298  virtual void On_MumAbandon(Roe_Female* mum);
299  virtual void BeginStep (void);
300  virtual void Step (void);
301  virtual void EndStep (void);
302  virtual void On_EndGroup();
303  Roe_Fawn(int x, int y,int size,int group,bool sex,Landscape* L,RoeDeer_Population_Manager* RPM);
304  virtual ~Roe_Fawn();
305 };
306 //---------------------------------------------------------------------------
307 
309 {
310 public:
311  Roe_Base* m_MyYoung[20]; //an array of pointers to all offspring
312  int m_MinInState[12]; //for energy calc., minuts spend in different states
313  //[0]=Disperse,[1]=InHeat,[2]=GiveB,[3]=Care,[4]=Run,[5]=Recov,[6]=Ignore,
314  //[7]=Evade,[8]=Rumi,[9]=Feed,[10]=Mate,[11]=EstablR
315  int m_MyGroup; //number of mygroup in grouplist
316  int SupplyIsPregnant() {if (m_Pregnant) return 1; else return 0;}
317  int SupplyYoung() {return m_NoOfYoung;}
318 
319 // STATES
320 private:
321  int FOnMature(void);
322  int FDie(void);
323  int FDisperse(void);
324  int FEstablishRange(void);
325  int FOnNewDay(void);
326  int FUpdateGestation(void);
327  int FGiveBirth(void);
328  int FFormGroup(void);
329  int FInHeat(void);
330  int FFeed(void);
331  int FRun();
332  int FRecover(void);
333  int FEvade();
334  int FIgnore();
335  int FRuminate(void);
336  int FCareForYoung(void);
337  int FMate(void);
338  int FUpdateEnergy(void);
339 protected:
340  bool m_Care;
344  int m_NoOfYoung; //this years fawns
348  vector<int> * m_GroupList;
349 
355 
356 //FUNCTIONS
357  int On_CanJoinGroup(Roe_Female* Female);
358  void On_UpdateGroup(int p_group_x,int p_group_y);
359  void On_ApproachOfDanger(int p_To_x,int p_To_y);
360  void Send_EndGroup();
361  virtual void On_EndGroup();
362 
363 public:
364  void Init (void);
365  virtual void BeginStep (void);
366  virtual void Step (void);
367  virtual void EndStep (void);
368  virtual void On_IsDead(Roe_Base* Someone, int whos_dead, bool fawn);
369  bool On_InitCare(Roe_Fawn* Fawn);
370  void On_EndCare(Roe_Fawn* Fawn);
371  int SupplyGroupNo() {return m_MyGroup;}
372  void AddFawnToList(Roe_Fawn* fawn);
373 
374  Roe_Female(int x, int y, int size, int age,int group,Roe_Female* mum, Landscape* L,RoeDeer_Population_Manager* RPM);
375  virtual ~Roe_Female();
376 };
377 //---------------------------------------------------------------------------
378 
379 class Roe_Male : public Roe_Adult_Base
380 {
381 private: //male states
382 
383 protected:
384  Roe_Female* m_My_Mate; //points to the female he is attending
385 
389  int m_MyFightlist; //this males record of encounters on global fightlist
390  Roe_Male* m_MyTMale; //young satellite males need a pointer to their "host"
391  Roe_Male* m_MySatellites[50];
392 
393  int MOnMature(void);
394  int MDie(void);
395  int MDisperse(void);
396  int MEstablishRange(void);
397  int MOnNewDay(void);
398  int MEstablishTerritory(void);
399  int MFight(void);
400  int MAttendFemale(void);
401  int MFeed(void);
402  int MRun();
403  int MRecover(void);
404  int MEvade();
405  int MIgnore();
406  int MRuminate(void);
407  int MMate(void);
408  int MUpdateEnergy(void);
409 
410 
411 public:
412  int m_MinInState[12]; //for energy calc., minuts spend in different states
413  //[0]=Establ.R,[1]=establ.T,[2]=Disperse,[3]=Run,[4]=Recov,[5]Evade,[6]=Ignore,
414  //[7]=Fight,[8]=AttendF,[9]=Rumi,[10]=Feed,[11]=Mate
415  void On_Expelled(Roe_Male* rival);
416  void On_NewHost(Roe_Male* host);
417  void On_ApproachOfDanger(int p_To_x,int p_To_y);
418  bool On_InHeat (Roe_Female* female,int p_x,int p_y);
419  void ClearFightlist();
420  bool SupplyHaveTerritory() {return m_HaveTerritory;}
421  Roe_Male* SupplyHost() {return m_MyTMale;}
422  bool On_Rank(Roe_Male* rival,double size,int age,int matings,bool where,bool range);
423  virtual void On_IsDead(Roe_Base* Someone, int whos_dead, bool fawn);
424  void AddSatellite(Roe_Male* sat);
425  void RemoveSatellite(Roe_Male* sat);
426  void Init (void);
427  virtual void BeginStep (void);
428  virtual void Step (void);
429  virtual void EndStep (void);
430 
431  Roe_Male(int x, int y,int size, int age,Roe_Female* mum,Landscape* L,RoeDeer_Population_Manager* RPM);
432  virtual ~Roe_Male();
433 };
434 //---------------------------------------------------------------------------
435 
437 {
438 public:
439  int x;
440  int y;
441  bool sex;
445  int group;
446  int size;
447  int age;
448  int ID;
449 };
450 //---------------------------------------------------------------------------
451 
452 //-----------------------------------------------------------------------------
454 {
455  public:
456  Roe_Base* GroupList[30];
457  int Size;
458  unsigned group_x;
459  unsigned group_y;
460 };
461 
462 //----------------------------------------------------------------------------
463 
464 class Roe_Grid
465 {
466  public:
467  Roe_Grid(Landscape* L);
468  ~Roe_Grid();
469  bool AddGridValue(int x,int y, int value);
470  int Supply_GridValue(int g_x,int g_y);
471  int Supply_GridCoord(int p_coor);
472  protected:
478  int* m_grid; //List of all cells in grid, min. cell size = 20 m
479 };
480 //----------------------------------------------------------------------------
481 
483 {
484  // Attributes.
485  protected:
487  ListOfDeer* m_GroupList[5000];//list of all groups in area
490  int m_FixCounter [5000];
491  ListOfMales* m_Fightlist [5000]; //keep fightlist for up to 5000 males
493  int Turnover;
494  int m_FixList[5000][20][2]; //for each animal keep up to 20 x,y positions
495  unsigned m_UpperList[100][2];
496  unsigned m_LowerList[100][2];
501 public:
503  MovementMap* m_MoveMap; //**ljk inserted on 25/7-2012
504  int DeadList[2000][2]; //animals that died within this year.
505  long StepCounter; //timestep in this simulation
512  int CreateNewGroup(Roe_Base* p_deer);
513  size_t Supply_GroupSize(int Group) {return m_GroupList[Group]->size();}
514  double Supply_AverageRangeQuality() {return m_AverageRangeQuality;}
515  double RangeQuality(int p_x,int p_y,int p_range);
516  double PercentForest(int p_x,int p_y,int p_range);
517  bool AddToGroup(Roe_Base* p_deer,int TheGroup);
518  bool RemoveFromGroup(Roe_Base* p_deer,int TheGroup);
519  void RemoveFromFightlist(Roe_Base* deer);
520  ListOfDeer* Supply_RoeGroup(int Group) {return m_GroupList[Group];}
521  bool InSquare(int p_x, int p_y,int p_sqx,int p_sqy, int p_range);
522  void CalculateArea(int p_a, int p_b,int ID);
523  int ScanGrid(int p_x, int p_y, bool avq);
524  int AddToArea(int g_x,int g_y, int p_range);
525  int AddToAreaCC(int g_x,int g_y, int p_range);
526  void Sort(int ID, int p_a, int p_b);
527  void Divide1(int ID, int p_a, int p_b);
528  void Divide2(int p_a, int p_b, int p_c,bool p_upper);
529  int SimW;
530  int SimH;
531  ListOfMales* SupplyFightlist(int ListNo) {if (ListNo!=-1) return m_Fightlist[ListNo];
532  else return NULL;}
533  void DeleteFightlist(int TheList);
534  int AddToFightlist(Roe_Male* rival, int ListNo);
535  int GetFixList();
536  void RemoveFixList(int listno);
537  void PreProcessLandscape();
538  void UpdateRanges();
539  // Other interface functions //ljk added 22/8-2012
540  virtual void TheAOROutputProbe();
541  virtual void TheRipleysOutputProbe(FILE* a_prb);
542  protected:
543  // Methods
544  void DoFirst();
545  void RunFirst();
546  void RunBefore();
547  void RunAfter();
548  void RunLast();
549 
550  public:
553  virtual void Init (void);
554  void CreateObjects(int, TAnimal *pvo,void* null ,
555  Deer_struct * data,int number);
556  ListOfMales* SupplyMales(int p_x,int p_y,int SearchRange);
557  ListOfMales* SupplyTMales(int p_x,int p_y,int SearchRange);
558  ListOfMales* SupplyMaleRC(int p_x,int p_y,int SearchRange);
559  ListOfFemales* SupplyFemales(int p_x,int p_y,int SearchRange);
560  ListOfFemales* SupplyFemaleRC(int p_x,int p_y,int SearchRange);
561  //void WriteToHRFile(std::string name, int month, int year);
562  //void WriteRandHR(std::string name, int total);
563  //void WriteToFixFile(Roe_Base*deer);
564  //void WriteFloatFile(std::string name, int male_f, int female_f);
565  //void WriteIDFile(std::string name, int p_ID, bool p_sex);
566  //void WriteDeadFile(std::string name, int p_year);
567  //void WriteAgeStructFile(std::string name, int year);
568  //void WriteReproFile(std::string name, int id, int young); //for Lene
569  void LOG(int day, int year); //daily log for debug purposes
570 
571 
572 };
573 
574 #endif
vector< Roe_Fawn * > Roe_FawnList
Definition: Roe_all.h:31
TRoeDeerStates
Definition: Roe_all.h:45
@ rds_MFeed
Definition: Roe_all.h:82
@ rds_MDisperse
Definition: Roe_all.h:57
@ rds_MRecover
Definition: Roe_all.h:69
@ rds_FAInit
Definition: Roe_all.h:93
@ rds_MRuminate
Definition: Roe_all.h:79
@ rds_FInHeat
Definition: Roe_all.h:62
@ rds_FARunToMother
Definition: Roe_all.h:67
@ rds_FEvade
Definition: Roe_all.h:73
@ rds_FFeed
Definition: Roe_all.h:81
@ rds_FOnNewDay
Definition: Roe_all.h:58
@ rds_MFight
Definition: Roe_all.h:76
@ rds_MAttendFemale
Definition: Roe_all.h:77
@ rds_FRuminate
Definition: Roe_all.h:78
@ rds_FAUpdateEnergy
Definition: Roe_all.h:52
@ rds_FDie
Definition: Roe_all.h:87
@ rds_FMate
Definition: Roe_all.h:85
@ rds_FGiveBirth
Definition: Roe_all.h:63
@ rds_FFormGroup
Definition: Roe_all.h:61
@ rds_FOnMature
Definition: Roe_all.h:47
@ rds_MOnMature
Definition: Roe_all.h:48
@ rds_MEstablishTerritory
Definition: Roe_all.h:55
@ rds_RUBBISH
Definition: Roe_all.h:94
@ rds_FUpdateGestation
Definition: Roe_all.h:49
@ rds_MEvade
Definition: Roe_all.h:74
@ rds_FEstablishRange
Definition: Roe_all.h:53
@ rds_FDisperse
Definition: Roe_all.h:56
@ rds_MDie
Definition: Roe_all.h:88
@ rds_FARuminate
Definition: Roe_all.h:80
@ rds_Initialise
Definition: Roe_all.h:46
@ rds_FARecover
Definition: Roe_all.h:70
@ rds_FRun
Definition: Roe_all.h:65
@ rds_FAOnNewDay
Definition: Roe_all.h:60
@ rds_FCareForYoung
Definition: Roe_all.h:64
@ rds_FUpdateEnergy
Definition: Roe_all.h:50
@ rds_MDeathState
Definition: Roe_all.h:91
@ rds_MRun
Definition: Roe_all.h:66
@ rds_FDeathState
Definition: Roe_all.h:90
@ rds_FRecover
Definition: Roe_all.h:68
@ rds_FADeathState
Definition: Roe_all.h:92
@ rds_FAHide
Definition: Roe_all.h:75
@ rds_MOnNewDay
Definition: Roe_all.h:59
@ rds_MEstablishRange
Definition: Roe_all.h:54
@ rds_FADie
Definition: Roe_all.h:89
@ rds_MMate
Definition: Roe_all.h:86
@ rds_FIgnore
Definition: Roe_all.h:71
@ rds_MUpdateEnergy
Definition: Roe_all.h:51
@ rds_FAFeed
Definition: Roe_all.h:83
@ rds_FASuckle
Definition: Roe_all.h:84
@ rds_MIgnore
Definition: Roe_all.h:72
vector< Roe_Base * > ListOfDeer
Definition: Roe_all.h:41
vector< Roe_Female * > ListOfFemales
Definition: Roe_all.h:40
vector< Roe_Female * > Roe_FemaleList
Definition: Roe_all.h:37
vector< Roe_Male * > ListOfMales
Definition: Roe_all.h:39
vector< Roe_Male * > Roe_MaleList
Definition: Roe_all.h:36
Definition: Roe_all.h:437
int x
Definition: Roe_all.h:439
RoeDeer_Population_Manager * Pop
Definition: Roe_all.h:443
int age
Definition: Roe_all.h:447
int size
Definition: Roe_all.h:446
int ID
Definition: Roe_all.h:448
bool sex
Definition: Roe_all.h:441
Landscape * L
Definition: Roe_all.h:442
int y
Definition: Roe_all.h:440
int group
Definition: Roe_all.h:445
Roe_Female * mum
Definition: Roe_all.h:444
The landscape class containing all environmental and topographical data.
Definition: landscape.h:113
Movement maps are used for rapid computing of animal movement.
Definition: MovementMap.h:51
Base class for all population managers.
Definition: PopulationManager.h:424
Definition: Roe_all.h:233
int m_float_x
Definition: Roe_all.h:240
int m_NewState
Definition: Roe_all.h:238
bool m_DestinationDecided
Definition: Roe_all.h:237
int m_DispCount
Definition: Roe_all.h:239
int m_float_y
Definition: Roe_all.h:241
Definition: Roe_all.h:101
bool m_float
Definition: Roe_all.h:114
int m_RangeCentre_y
Definition: Roe_all.h:108
int m_FixlistNumber
Definition: Roe_all.h:119
unsigned Alive
Definition: Roe_all.h:122
virtual int WhatState()
Definition: Roe_all.h:226
int m_LengthFeedPeriod
Definition: Roe_all.h:136
virtual void On_MumAbandon(Roe_Female *)
Definition: Roe_all.h:216
int m_OldRange_y
Definition: Roe_all.h:112
int m_OldRange_x
Definition: Roe_all.h:111
int SimH
Definition: Roe_all.h:145
int SimW
Definition: Roe_all.h:144
int NutriValue(int polyref)
int m_distrc
Definition: Roe_all.h:142
void Ignore(int p_To_x, int p_To_y)
RoeDeer_Population_Manager * m_OurPopulation
Definition: Roe_all.h:104
bool m_Disperse
Definition: Roe_all.h:115
bool m_Sex
Definition: Roe_all.h:120
virtual void On_UpdateGroup(int, int)
Definition: Roe_all.h:221
int m_RecovCount
Definition: Roe_all.h:133
int m_Cross_x
Definition: Roe_all.h:130
bool m_IsDead
Definition: Roe_all.h:121
int AssessHabitat(int p_x, int p_y)
int timestep
Definition: Roe_all.h:128
int AssessHabitat(int polyref)
virtual void On_IsDead(Roe_Base *, int, bool)
Definition: Roe_all.h:217
int m_Size
Definition: Roe_all.h:106
int DirectionToCC(int p_x, int p_y, int p_To_x, int p_To_y)
Definition: Roe_all.h:158
int LegalHabitatCC(int p_x, int p_y)
Definition: Roe_all.h:172
int m_Cross_y
Definition: Roe_all.h:131
int m_RangeCentre_x
Definition: Roe_all.h:107
Roe_Female * Mum
Definition: Roe_all.h:117
bool m_HaveRange
Definition: Roe_all.h:116
int m_SearchRange
Definition: Roe_all.h:113
int m_FeedCount
Definition: Roe_all.h:135
int m_danger_x
Definition: Roe_all.h:139
int m_LastState
Definition: Roe_all.h:138
int m_danger_y
Definition: Roe_all.h:140
int m_RumiCount
Definition: Roe_all.h:134
virtual void On_EndGroup()
Definition: Roe_all.h:218
int m_ID
Definition: Roe_all.h:118
int CoverCC(int p_x, int p_y)
Definition: Roe_all.h:188
int m_weightedstep
Definition: Roe_all.h:143
int m_Reserves
Definition: Roe_all.h:109
virtual void Send_IsDead()
Definition: Roe_all.h:219
int m_Age
Definition: Roe_all.h:105
double m_HomeRange
Definition: Roe_all.h:110
virtual void On_ChangeGroup(int)
Definition: Roe_all.h:220
double m_EnergyGained
Definition: Roe_all.h:132
int NutriValueCC(int p_x, int p_y)
Definition: Roe_all.h:196
unsigned IsAlive()
Definition: Roe_all.h:123
int DistanceToCC(int p_x, int p_y, int p_To_x, int p_To_y)
Definition: Roe_all.h:150
int m_LengthRuminate
Definition: Roe_all.h:137
TRoeDeerStates CurrentRState
Definition: Roe_all.h:103
int SupplyReserves()
Definition: Roe_all.h:125
void WalkToCC(int pos_x, int pos_y)
Definition: Roe_all.h:209
Definition: Roe_all.h:254
int m_BedSite_y
Definition: Roe_all.h:277
bool m_Orphan
Definition: Roe_all.h:274
int m_MyGroup
Definition: Roe_all.h:292
int m_MinHourlyCare
Definition: Roe_all.h:273
bool m_Mature
Definition: Roe_all.h:272
int m_Bedsite_x
Definition: Roe_all.h:276
int m_memorypointer
Definition: Roe_all.h:283
bool m_InHide
Definition: Roe_all.h:275
int m_Agegroup
Definition: Roe_all.h:271
unsigned m_Count
Definition: Roe_all.h:278
Definition: Roe_all.h:309
int m_NoOfYoung
Definition: Roe_all.h:344
int m_OptGroupSize
Definition: Roe_all.h:350
int SupplyGroupNo()
Definition: Roe_all.h:371
bool m_HaveGroup
Definition: Roe_all.h:351
bool m_GroupUpdated
Definition: Roe_all.h:352
int SupplyIsPregnant()
Definition: Roe_all.h:316
int m_DaysSinceParturition
Definition: Roe_all.h:345
void Init(void)
bool m_Care
Definition: Roe_all.h:340
bool m_WasInHeat
Definition: Roe_all.h:354
vector< int > * m_GroupList
Definition: Roe_all.h:348
bool m_NatalGroup
Definition: Roe_all.h:347
int m_HeatCount
Definition: Roe_all.h:353
Roe_Male * m_My_Mate
Definition: Roe_all.h:343
int m_Gestationdays
Definition: Roe_all.h:341
int SupplyYoung()
Definition: Roe_all.h:317
int m_MyGroup
Definition: Roe_all.h:315
bool m_Pregnant
Definition: Roe_all.h:342
bool m_WantGroup
Definition: Roe_all.h:346
Definition: Roe_all.h:465
Landscape * m_LS
Definition: Roe_all.h:473
int * m_grid
Definition: Roe_all.h:478
int m_extent_y
Definition: Roe_all.h:476
int m_SizeOfCells
Definition: Roe_all.h:474
int m_maxcells
Definition: Roe_all.h:477
int m_extent_x
Definition: Roe_all.h:475
Definition: Roe_all.h:380
Roe_Male * SupplyHost()
Definition: Roe_all.h:421
bool SupplyHaveTerritory()
Definition: Roe_all.h:420
Roe_Female * m_My_Mate
Definition: Roe_all.h:384
void Init(void)
bool m_HaveTerritory
Definition: Roe_all.h:386
Roe_Male * m_MyTMale
Definition: Roe_all.h:390
int m_NoOfMatings
Definition: Roe_all.h:387
int m_NumberOfFights
Definition: Roe_all.h:388
int m_MyFightlist
Definition: Roe_all.h:389
Definition: Roe_all.h:483
double m_AverageRangeQuality
Definition: Roe_all.h:489
ListOfMales * SupplyFightlist(int ListNo)
Definition: Roe_all.h:531
int SimH
Definition: Roe_all.h:530
ListOfDeer * Supply_RoeGroup(int Group)
Definition: Roe_all.h:520
int m_CriticalWeight_Males
Definition: Roe_all.h:510
int m_NoGroups
Definition: Roe_all.h:488
int m_MinWeight_Females
Definition: Roe_all.h:509
long StepCounter
Definition: Roe_all.h:505
Roe_Grid * m_TheGrid
Definition: Roe_all.h:486
int m_CriticalWeight_Females
Definition: Roe_all.h:511
int Turnover
Definition: Roe_all.h:493
int SimW
Definition: Roe_all.h:529
int m_gridextenty
The number of cells tall in the qual grid.
Definition: Roe_all.h:500
int m_gridextentx
The number of cells wide in the qual grid.
Definition: Roe_all.h:498
int m_FemaleDispThreshold
Definition: Roe_all.h:507
double Supply_AverageRangeQuality()
Definition: Roe_all.h:514
MovementMap * m_MoveMap
Map of suitability for movement.
Definition: Roe_all.h:503
void LOG(int day, int year)
long m_totalarea
Definition: Roe_all.h:492
int m_MaleDispThreshold
Definition: Roe_all.h:506
int m_MinWeight_Males
Definition: Roe_all.h:508
size_t Supply_GroupSize(int Group)
Definition: Roe_all.h:513
Part of the basic ALMaSS system (obselete)
Definition: PopulationManager.h:187
The base class for all ALMaSS animal classes.
Definition: PopulationManager.h:205
Definition: Roe_all.h:454
int Size
Definition: Roe_all.h:457
unsigned group_x
Definition: Roe_all.h:458
unsigned group_y
Definition: Roe_all.h:459
Data structure to hold & output probe data probe data is designed to be used to return the number of ...
Definition: PopulationManager.h:284
TTypesOfLandscapeElement
Definition: tole_declaration.h:36